<%@ page language="java" contentType="text/html; charset=utf-8"  pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>****管理系统</title>
  <meta name="description" content="è¿æ¯ä¸ä¸ª user é¡µé¢">
  <meta name="keywords" content="user">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <meta name="renderer" content="webkit">
  <meta http-equiv="Cache-Control" content="no-siteapp" />
  <meta name="apple-mobile-web-app-title" content="Amaze UI" />
  <link rel="icon" type="image/png" href="${pageContext.request.contextPath}/assets/i/favicon.png">
  <link rel="apple-touch-icon-precomposed" href="${pageContext.request.contextPath}/assets/i/app-icon72x72@2x.png">
  <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/amazeui.min.css"/>
  <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/admin.css">
</head>
	<body>
		<header class="am-topbar am-topbar-inverse admin-header">
		  <div class="am-topbar-brand">
		    <strong>**管理系统</strong> <small>人员管理</small>
		  </div>
		
		  <button class="am-topbar-btn am-topbar-toggle am-btn am-btn-sm am-btn-success am-show-sm-only" data-am-collapse="{target: '#topbar-collapse'}"><span class="am-sr-only">导航切换</span> <span class="am-icon-bars"></span></button>
		
		  <div class="am-collapse am-topbar-collapse" id="topbar-collapse">
		
		    <ul class="am-nav am-nav-pills am-topbar-nav am-topbar-right admin-header-list">
		      <li><a href="javascript:;"><span class="am-icon-envelope-o"></span> 收件箱 <span class="am-badge am-badge-warning">5</span></a></li>
		      <li class="am-dropdown" data-am-dropdown>
		        <a class="am-dropdown-toggle" data-am-dropdown-toggle href="javascript:;">
		          <span class="am-icon-users"></span> 管理员 <span class="am-icon-caret-down"></span>
		        </a>
		        <ul class="am-dropdown-content">
		          <li><a href="#"><span class="am-icon-user"></span> 资料</a></li>
		          <li><a href="#"><span class="am-icon-cog"></span> 设置</a></li>
		          <li><a href="#"><span class="am-icon-power-off"></span> 退出</a></li>
		        </ul>
		      </li>
		      <li class="am-hide-sm-only"><a href="javascript:;" id="admin-fullscreen"><span class="am-icon-arrows-alt"></span> <span class="admin-fullText">开启全屏</span></a></li>
		    </ul>
		  </div>
		</header>

<div class="am-cf admin-main">
  <!-- sidebar start -->
  <div class="admin-sidebar am-offcanvas" id="admin-offcanvas">
    <div class="am-offcanvas-bar admin-offcanvas-bar">
      <ul class="am-list admin-sidebar-list">
        <li><a href="admin-index.html"><span class="am-icon-home"></span> 首页</a></li>
        <li class="admin-parent">
          <a class="am-cf" data-am-collapse="{target: '#collapse-nav'}"><span class="am-icon-file"></span> 页面模块 <span class="am-icon-angle-right am-fr am-margin-right"></span></a>
          <ul class="am-list am-collapse admin-sidebar-sub am-in" id="collapse-nav">
            <li><a href="admin-user.html" class="am-cf"><span class="am-icon-check"></span> 个人资料<span class="am-icon-star am-fr am-margin-right admin-icon-yellow"></span></a></li>
            <li><a href="admin-help.html"><span class="am-icon-puzzle-piece"></span> 帮助页</a></li>
            <li><a href="admin-gallery.html"><span class="am-icon-th"></span> 相册页面<span class="am-badge am-badge-secondary am-margin-right am-fr">24</span></a></li>
            <li><a href="admin-log.html"><span class="am-icon-calendar"></span> 系统日志</a></li>
            <li><a href="admin-404.html"><span class="am-icon-bug"></span> 404</a></li>
          </ul>
        </li>
        <li><a href="admin-table.html"><span class="am-icon-table"></span> 表格</a></li>
        <li><a href="admin-form.html"><span class="am-icon-pencil-square-o"></span> 表单</a></li>
        <li><a href="#"><span class="am-icon-sign-out"></span> 注销</a></li>
      </ul>

      <div class="am-panel am-panel-default admin-sidebar-panel">
        <div class="am-panel-bd">
          <p><span class="am-icon-bookmark"></span> 公告</p>
          <p>时光静好，与君语；细水流年，与君同。—— Amaze UI</p>
        </div>
      </div>

      <div class="am-panel am-panel-default admin-sidebar-panel">
        <div class="am-panel-bd">
          <p><span class="am-icon-tag"></span> wiki</p>
          <p>Welcome to the Amaze UI wiki!</p>
        </div>
      </div>
    </div>
  </div>
  <!-- sidebar end -->

  <!-- content start -->
  <div class="admin-content">
    <div class="admin-content-body">
      <div class="am-cf am-padding am-padding-bottom-0">
        <div class="am-fl am-cf"><strong class="am-text-primary am-text-lg">人员管理</strong><small></small></div>
      </div>
      <hr/>
	  
	  <div class="am-g">
	  	<div class="am-u-sm-12"></div>
	  	<div></div>
	  	<div></div>
	  </div>
	  
	  <!-- user signle panel -->
      <div class="am-g">
        <div class="am-u-sm-12 am-u-md-4 am-u-md-push-8">
          <div class="am-panel am-panel-default">
            <div class="am-panel-bd">
              <div class="am-g">
                <div class="am-u-md-4">
                  <img class="am-img-circle am-img-thumbnail" src="http://s.amazeui.org/media/i/demos/bw-2014-06-19.jpg?imageView/1/w/200/h/200/q/80" alt=""/>
                </div>
                <div class="am-u-md-8">
                  <p>你可以使用<a href="#">gravatar.com</a>提供的头像或者使用本地上传头像。 </p>
                  <form class="am-form">
                    <div class="am-form-group">
                      <input type="file" id="user-pic">
                      <p class="am-form-help">请选择要上传的文件...</p>
                      <button type="button" class="am-btn am-btn-primary am-btn-xs">保存</button>
                    </div>
                  </form>
                </div>
              </div>
            </div>
          </div>

          <div class="am-panel am-panel-default">
            <div class="am-panel-bd">
              <div class="user-info">
                <p>等级信息</p>
                <div class="am-progress am-progress-sm">
                  <div class="am-progress-bar" style="width: 60%"></div>
                </div>
                <p class="user-info-order">当前等级：<strong>LV8</strong> 活跃天数：<strong>587</strong> 距离下一级别：<strong>160</strong></p>
              </div>
              <div class="user-info">
                <p>信用信息</p>
                <div class="am-progress am-progress-sm">
                  <div class="am-progress-bar am-progress-bar-success" style="width: 80%"></div>
                </div>
                <p class="user-info-order">信用等级：正常当前 信用积分：<strong>80</strong></p>
              </div>
            </div>
          </div>

        </div>

        <div class="am-u-sm-12 am-u-md-8 am-u-md-pull-4">
          <form class="am-form am-form-horizontal" id="userDetailForm">
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">登录名 </label>
              <div class="am-u-sm-9">
                <input type="text" id="userName" name="userName" placeholder="登录名 ">
                <!-- <small>输入你的名字，让我们记住你。</small> -->
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">姓名 </label>
              <div class="am-u-sm-9">
                <input type="text" id="allName" name="allName" placeholder="姓名 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">性别 </label>
              <div class="am-u-sm-9">
                <input type="text" id="sexId" name="sexId" placeholder="性别 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">出生日期 </label>
              <div class="am-u-sm-9">
                <input type="text" id="birthDay" name="birthDay" placeholder="出生日期 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">籍贯 </label>
              <div class="am-u-sm-9">
                <input type="text" id="birthRegion" name="birthRegion" placeholder="籍贯">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">职别 </label>
              <div class="am-u-sm-9">
                <input type="text" id="positionId" name="positionId" placeholder="职别 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">电话号码 </label>
              <div class="am-u-sm-9">
                <input type="number" pattern="[0-9]*" id="phoneNo" name="phoneNo" placeholder="电话号码">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">座机 </label>
              <div class="am-u-sm-9">
                <input type="number" pattern="[0-9]*" id="callNo" name="callNo" placeholder="座机 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-email" class="am-u-sm-3 am-form-label">电子邮件 </label>
              <div class="am-u-sm-9">
                <input type="email" id="email" name="email" placeholder="输入你的电子邮件">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">工号 </label>
              <div class="am-u-sm-9">
                <input type="number" pattern="[0-9]*" id="workId" name="workId" placeholder="工号 ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">单位Id </label>
              <div class="am-u-sm-9">
                <input type="text" id="workCompanyId" name="workCompanyId" placeholder="单位Id ">
              </div>
            </div>
            <div class="am-form-group">
              <label for="user-name" class="am-u-sm-3 am-form-label">状态 </label>
              <div class="am-u-sm-9">
                <input type="text" id="valid" name="valid" placeholder="状态">
              </div>
            </div>

            <div class="am-form-group" style="display:none">
              <label for="user-QQ" class="am-u-sm-3 am-form-label">QQ</label>
              <div class="am-u-sm-9">
                <input type="number" pattern="[0-9]*" id="user-QQ" placeholder="输入你的QQ号码">
              </div>
            </div>
            <div class="am-form-group" style="display:none">
              <label for="user-weibo" class="am-u-sm-3 am-form-label">微博 </label>
              <div class="am-u-sm-9">
                <input type="text" id="user-weibo" placeholder="输入你的微博 / Twitter">
              </div>
            </div>
            <div class="am-form-group" style="display:none">
              <label for="user-intro" class="am-u-sm-3 am-form-label">简介 </label>
              <div class="am-u-sm-9">
                <textarea class="" rows="5" id="user-intro" placeholder="输入个人简介"></textarea>
              </div>
            </div>
            <div class="am-u-sm-9 am-u-sm-push-3 am-u-sm-centered">
                <button type="button" class="am-btn am-btn-primary"  onclick="userModify()">保存修改</button>
            </div>
          </form>
        </div>
      </div>
      <!-- user signle panel end -->
    </div>

    <footer class="admin-content-footer">
      <hr>
      <div align="center">
      	<p class="am-padding-left">© 2014 AllMobilize, Inc. Licensed under MIT license.</p>
      </div>
    </footer>

  </div>
  <!-- content end -->

</div>

		<a href="#" class="am-icon-btn am-icon-th-list am-show-sm-only admin-menu" data-am-offcanvas="{target: '#admin-offcanvas'}"></a>
		
		<footer>
		  <hr>
		  <p class="am-padding-left">© 2014 AllMobilize, Inc. Licensed under MIT license.</p>
		</footer>
		
		<!--[if lt IE 9]>
		<script src="http://libs.baidu.com/jquery/1.11.3/jquery.min.js"></script>
		<script src="http://cdn.staticfile.org/modernizr/2.8.3/modernizr.js"></script>
		<script src="assets/js/amazeui.ie8polyfill.min.js"></script>
		<![endif]-->
		
		<!--[if (gte IE 9)|!(IE)]><!-->
		<script src="${pageContext.request.contextPath}/js/jquery.js"></script>
		<script src="${pageContext.request.contextPath}/assets/js/amazeui.min.js"></script>
		<script src="${pageContext.request.contextPath}/assets/js/app.js"></script>
		<script type="text/javascript">
			function userModify(){
				//1.userName不能为空且有效
				var data = $("#userDetailForm").serialize();
				$.post("${pageContext.request.contextPath}/people/peopleModify.action",data,function(res){
					var re = eval("("+res+")");
					if(re.success){
						alert("提交成功！");
						$("#orgCompany").val();
					}else{
						if(re.isExist){
							alert("用户名已存在，请重新输入!");
						}
					};
				});
			}
		</script>
	</body>
</html>
